#ifndef FRMTCPCLIENT_H
#define FRMTCPCLIENT_H

#include <QWidget>
#include "frmmain.h"

namespace Ui {
class frmtcpclient;
}

class frmtcpclient : public QWidget
{
    Q_OBJECT

public:
    explicit frmtcpclient(QWidget *parent = nullptr);
    ~frmtcpclient();

private slots:
    void on_connectButton_clicked();
    void on_enterCommandModeButton_clicked();
    void on_exitCommandModeButton_clicked();
    void on_applyConfigButton_clicked();
    void on_resetButton_clicked();

private:
    Ui::frmtcpclient *ui;
    frmmain *mainWindow;
    bool isCommandMode;

    void sendCommandModeCommand(bool enter);
    void enableConfigControls(bool enable);
    void resetConfigFields();
    void updateMainResponse(const QString &msg);
};

#endif // FRMTCPCLIENT_H